home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amoszine 2
/
Amoszine 2.adf
/
MORE_SOURCE_CODE
/
buttons.AMOS
/
buttons.amosSourceCode
Wrap
AMOS Source Code
|
1992-02-26
|
1KB
|
36 lines
Rem
Rem A nice little button routine that can be used in any option selecting
Rem routine. size and shape of the buttons can be easily changed.
Rem David Pickin
Rem
Screen Open 0,320,256,32,Lowres
Curs Off : Flash Off : Cls 0
Colour 0,$888 : Colour 24,$BBB : Colour 23,$666
Colour 17,$555 : Colour 18,$999 : Colour 19,$BBB : Rem mouse colours
Reserve Zone 4
A1=100 : B1=100 : A2=120 : B2=120 : Set Zone 1,A1,B1 To A2,B2 : Gosub SHADEUP2
A1=150 : B1=100 : A2=170 : B2=120 : Set Zone 2,A1,B1 To A2,B2 : Gosub SHADEUP2
A1=200 : B1=100 : A2=220 : B2=120 : Set Zone 3,A1,B1 To A2,B2 : Gosub SHADEUP2
A1=150 : B1=150 : A2=170 : B2=170 : Set Zone 4,A1,B1 To A2,B2 : Gosub SHADEUP2
A1=0
A:
Repeat
If Mouse Key=2 Then End
Until Mouse Key
Z=Mouse Zone
If Z=1 : P1=100 : Q1=100 : P2=120 : Q2=120 : Gosub SHADEDO2 : End If
If Z=2 : P1=150 : Q1=100 : P2=170 : Q2=120 : Gosub SHADEDO2 : End If
If Z=3 : P1=200 : Q1=100 : P2=220 : Q2=120 : Gosub SHADEDO2 : End If
If Z=4 : P1=150 : Q1=150 : P2=170 : Q2=170 : Gosub SHADEDO2 : End If
Wait 20
Goto A
SHADEUP2:
Ink 24 : Polyline A1,B2 To A1,B1 To A2,B1
Ink 23 : Polyline A2,B1 To A2,B2 To A1,B2
Return
SHADEDO2:
If A1>0 Then Gosub SHADEUP2
Ink 23 : Polyline P1,Q2 To P1,Q1 To P2,Q1
Ink 24 : Polyline P2,Q1 To P2,Q2 To P1,Q2
A1=P1 : A2=P2 : B1=Q1 : B2=Q2
Return